package cn.tedu.eliminate;

import javax.swing.JPanel;
import javax.swing.JFrame;

/**
 * 窗口类
 */
public class World extends JPanel {
    public static final int WIDTH = 429;//窗口的宽
    public static final int HEIGHT = 570;//窗口的高
    public static final int ROWS = 8;//8hang
    public static final int COLS = 6;//6列
    public static final int ELEMENT_SIZE = 60;//元素大小
    public static final int OFFSET = 30;//偏移量
    private Element[][] elements = new Element[ROWS][COLS];//元素数组

        /**
         * 启动执行
         * 鼠标监听
         */
        public void start () {

        }

        /**
         * 主方法
         *
         * @param args
         */
        public static void main (String[]args){
            JFrame frame = new JFrame();
            World world = new World();
            world.setFocusable(true);
            frame.add(world);
            frame.setSize(WIDTH + 18, HEIGHT + 47);
            frame.setLocationRelativeTo(null);
            frame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
            frame.setVisible(true);
            world.start();
        }
    }
